﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace COFE.Core.Actions
{
    //public enum WorkAntStatus { Waiting, Working, Success, Failed }

    /// <summary>
    /// Perform swi assigned by IWorkScheduler.
    /// </summary>
    public interface IWorkSchedulerAnt
    {
        int Id { get; }

        /// <summary>
        /// Sets or gets the current Work of this ant.        
        /// </summary>        
        ISchedule CurrentSchedule { get; }

        /// <summary>
        /// Gets which WorkScheduler to report to, this is set in constructor.
        /// </summary>
        IWorkScheduler WorkScheduler { get; }

        /// <summary>
        /// Abort the current SimpleWork schedule.
        /// </summary>        
        void Abort();


        /// <summary>
        /// Set CurrentSchedule to null, and WorkAntStatus to initialized.
        /// </summary>
        void Reset();

        void AssignWork(ISchedule scheduledWork);

        WorkAntStatus Status { get; }
    }
}
